package school;

import school.course.Course;

public class StudentCourseLink {

	private Course course=null;
	private Student student=null;
	
	public StudentCourseLink (Student student, Course course) {
		if (student!=null && course !=null) {
			this.student=student;
			this.course=course;
		}
	}
	
	public void destroy() {
		course=null;
		student=null;
	}
	
	public boolean isLinked() {
		return (course==null || student==null);
	}
	
	public Student getStudent() {
		return student;
	}
	
	public Course getCourse(){
		return course;
	}
}
